// pages/addressInfo/addressInfo.js
Page({

  /**
   * 页面的初始数据
   */
  data: {
      city:'',
      type:''
  },

  /**
   * 生命周期函数--监听页面加载
   */
  onLoad(options) {
    let type = options.type
    this.setData({
      type:type
    })
    wx.request({
      url: 'http://www.house.com/index.php/api/houseCity',
      success:res=>{
        this.setData({
          city:res.data.data
        })
      }
    })
  },
  getAddress(e){
      let type = this.data.type
      var city=e.currentTarget.dataset.address
      wx.setStorageSync('city', city)
      wx.navigateBack({
        delta: 0,
      })
  }
})